package org.hu.service.impl;

import org.hu.entity.pojo.User;
import org.hu.service.UserMapper;
import org.hu.service.UserService;
import org.springframework.stereotype.Service;

@Service
public class UserServiceImpl implements UserService {

    private UserMapper userMapper;
    public UserServiceImpl(UserMapper userMapper) {
        this.userMapper = userMapper;
    }

    // 根据用户名查询用户
    @Override
    public User getUserByUsername(User user) {
        return userMapper.getByUsername(user);
    }
}
